/*
 * Copyright (c) 2006-2018, RT-Thread Development Team
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Change Logs:
 * Date           Author       Notes
 * 2019-09-25     tyustli   first version
 */

#include <rthw.h>
#include <rtthread.h>
#include "board.h"
#include "DrvUART010.h"
#include "interrupt.h"
#include "timer.h"
void rt_hw_board_init(void)
{
    // rt_hw_interrupt_init();
    fLib_Int_Init();
    timer_prepare_for_os(RT_TICK_PER_SECOND);

#ifdef RT_USING_HEAP
    /* init memory system */
    rt_system_heap_init(RT_HW_HEAP_BEGIN, RT_HW_HEAP_END);
#endif

    /* init uart */
    fLib_SerialInit(DEBUG_CONSOLE, DEFAULT_CONSOLE_BAUD, PARITY_NONE, 0, 8);

#ifdef RT_USING_COMPONENTS_INIT
    rt_components_board_init();
#endif
	return;
}

